<?php

namespace Admin\Model;
use Think\Model;

class SnameModel extends Model {
    protected $_validate = array(
        array('title', 'require', '名称不能为空', self::MUST_VALIDATE , 'regex', self::MODEL_BOTH),
        array('dec', 'require', '描述不能为空', self::MUST_VALIDATE , 'regex', self::MODEL_BOTH),
        array('status', 'require', '状态不能为空', self::MUST_VALIDATE , 'regex', self::MODEL_BOTH),
    );

    protected $_auto = array(
        array('ctime', NOW_TIME, self::MODEL_INSERT),
        array('status', '1', self::MODEL_BOTH),
    );
}